<template>
<div class="layerRtb layerRtb-threecolumn layerRtb-right">
    <three-title :title="{name:'款项明细'}" :close="false">
      <span tag="i" class="rig_close fr" @click="$parent.$parent.clickFourShow()"></span>
    </three-title>
    <div class="layerRtb-scroll thinScroll" v-scrollHeight = "137">
        <div class="analyItem" v-for="(item,index) in receviableFunds" :key="index">
            <p class="analyItemTit tx-center">{{item.PeriodName}}</p>
            <div class="analyItemCon">
                    <p class="col-md-4">
                        <span class="cLightGray pr8">应收</span>
                        <span >{{item.Receivable}}</span>
                    </p>
                    <p class="col-md-4">
                        <span class="cLightGray pr8">应收日期</span>
                        <span class="c666">{{item.PeriodTime}}</span>
                    </p>
                    <p class="col-md-4">
                        <span class="cLightGray pr8">已收</span>
                        <span class="c666">{{item.Received}}</span>
                    </p>
            </div>
        </div>
        <!-- <div class="analyItem">
            <p class="analyItemTit tx-center">二期款</p>
            <div class="analyItemCon">
                    <p class="col-md-4">
                        <span class="cLightGray pr8">应收</span>
                        <span ></span>
                    </p>
                    <p class="col-md-4">
                        <span class="cLightGray pr8">应收日期</span>
                        <span class="c666"></span>
                    </p>
                    <p class="col-md-4">
                        <span class="cLightGray pr8">已收</span>
                        <span class="c666"></span>
                    </p>
            </div>
        </div> -->
        <!-- <div class="analyItem">
            <p class="analyItemTit tx-center">质保</p>
            <div class="analyItemCon">

            </div>
        </div> -->
    </div>
    <div class="layerRtb-footer">
        <div class="analyItem">
            <p class="analyItemTit tx-center">综合</p>
            <div class="analyItemCon">
                <!-- <p class="fl col-md-9"></p>
                <p class="fr col-md-3">
                    <span class="cLightGray">统计</span>
                    <span class="cGreen fz14 bold">0分</span>
                </p>
                <p class="fl"><span class="circlemark circlemark-green">优</span></p> -->
            </div>
        </div>
        <!-- <div class="tx-center">
            <input type="button" class="uiBtn-normal uiBtn-blue" value="确定">
        </div> -->
    </div>

</div>
</template>
<script>
import {
    getIGCReceivableFunds
} from '../../../../Resources/Api'
export default {
    props: ['orderNo'],
    data () {
        return {
            receviableFunds: []
        }
    },
    created () {
        this.GetReceivableFunds()
    },
    methods: {
        GetReceivableFunds () {
            let _this = this
            _this.receviableFunds = []
            getIGCReceivableFunds({
                orderId: this.orderNo
            }).then(results => {
                if (results.data.Body) {
                    _this.receviableFunds = results.data.Body
                    // console.log(this.receviableFunds)
                } else {
                    _this.receviableFunds = [{
                        PeriodName: '',
                        Receivable: 0,
                        PeriodTime: '',
                        Received: 0
                    }]
                }
            }).catch(error => {
                console.log(error)
            })
        }
    }
}
</script>
